Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bazel,dev: fix staging behavior from non-default configurations #130831

Merged

Conversation

rickystewart
Copy link
Collaborator

Backport:

Please see individual PRs for details.

/cc @cockroachdb/release

Release note: None
Epic: None
Release justification: Non-production code changes

... and switch our default compilation mode to `dbg`.

Under `fastbuild`, built binaries are stripped. This is not the case
with `dbg`. Have `dev doctor` recommend using `dbg`, and either way
make `dev` resilient to whatever kind of `--compilation_mode` you're
using.

In principle or theory `dbg` is slower than `fastbuild`, but for the Go
compiler it generates debuggable binaries by default and you have to
opt-in to stripping, so it shoould make no real difference.

Now, we think of the `--compilation_mode` simply as follows: `dbg` is
the default that everyone is opted into by default unless they
explicitly set `-c opt` (we use this for release). For now I don't see
a reason anyone would need `fastbuild`.

Epic: CRDB-17171
Release note: None
Closes: cockroachdb#106820
We added support for building in non-default configurations/compilation
modes in a previous PR, but this was buggy and we were never actually
using the configuration arguments in `bazel info`, so staging was always
happening from the `fastbuild` location. This PR fixes that buggy
behavior, so staging will happen from the appropriate source location.

Epic: CRDB-17171
Release note: None
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@rickystewart rickystewart marked this pull request as ready for review September 16, 2024 21:28
@rickystewart rickystewart requested a review from a team as a code owner September 16, 2024 21:28
@rickystewart rickystewart merged commit 6a51c13 into cockroachdb:release-23.1 Sep 16, 2024
6 checks passed
@rickystewart rickystewart deleted the backport23.1-106944-123241 branch September 16, 2024 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants